﻿using System.Collections.Generic;
using ZilLion.Service.WeChatMall.Domain.Entitys.AppInfo;

namespace ZilLion.Service.WeChatMall.Domain.Services.Interface
{
    public interface IAppInfoService
    {
        /// <summary>
        ///     获得当前客户的所有微信app信息
        /// </summary>
        /// <param name="zlcompanykey"></param>
        /// <returns></returns>
        IList<AppInfoDto> GetApps(string zlcompanykey);

        /// <summary>
        ///     新增微信APP
        /// </summary>
        /// <param name="dto"></param>
        /// <returns></returns>
        AppInfoDto SaveAppInfo(AppInfoDto dto);

        /// <summary>
        ///     根据ID 获取APP信息
        /// </summary>
        /// <param name="appid"></param>
        /// <returns></returns>
        AppInfoDto GetAppByAppId(string appid);

        /// <summary>
        ///     删除
        /// </summary>
        /// <param name="appid"></param>
        void DeleteApp(string appid);

        /// <summary>
        /// 批量保存商户默认货品关系
        /// </summary>
        /// <param name="list"></param>
        void SaveAppGsRelationShip(IList<AppGsRelationShipEntity> list);

        /// <summary>
        /// 检查appid 和crmurl 配对是否合法
        /// </summary>
        /// <param name="appid"></param>
        /// <param name="crmurl"></param>
        /// <returns></returns>
        bool CheckAppIdValid(string appid, string crmurl);
    }
}